<?php

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

namespace app\index\controller;
use think\Controller;
use think\Request;
use think\Db;
use app\index\model\Product;
/**
 * Description of Home
 *
 * @author hasee
 */
class Home {
    //put your code here
    public function index(){
//        $result=Db::name("goods")
//                ->where("is_best",1)
//                ->limit(4)
//                ->select();
        $result=Product::where('pisnew',1)->select();
        $result1=Product::where('pishot',1)->select();
        $result2=Product::where('pischeap',1)->select();

        
        
//        var_dump($result);       
//        var_dump($result1);
        
            return view("/home/index",['data'=>$result,'data1'=>$result1,'data2'=>$result2]);

        
    }
}